/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.mycompany.chatapp.Databaseacces;

import java.util.List;
import org.xmldb.api.base.ResourceSet;
import org.xmldb.api.base.XMLDBException;
/**
 *
 * @author bgorriz
 */
public class ImpDBActionResult implements DBActionResult {

        private boolean ok;
        private String errorMsg;
        private Throwable exception;
        private List<Object> result;
    
    public boolean isOk() {
       return ok;
        
    }
    
    

    public String getErrorMsg() {
return this.errorMsg;    }

    public Throwable getException() {
return this.exception;    }

    public List<Object>  getResult() {
return this.result;    }

    public void setErrorMsg(String a_ErrorMsg) {
this.errorMsg= a_ErrorMsg;    }

    public void setException(Throwable a_Exception) {
this.exception=a_Exception;    }

    public void setResult(List<Object>  a_Result) {
this.result=a_Result;
    }
    
    public void setOk(boolean set){
    this.ok=set;
    
    }

    void setResultOk(List<Object> queryresult) {
        this.ok=true;
        this.result=queryresult;
    }

   

    void setResultWrong(XMLDBException ex, String message) {
        this.ok=false;
        this.errorMsg=message;
        this.exception=ex;
    }

    void setResult(String string) {
        this.ok=false;
        this.errorMsg=string;
    }
}
